package com.code.day13;

public class Day13StringGet {
    public static void main(String[] args) {
        String s="abcdefg";
        String newstr1 = s.concat("hahaha");

        System.out.println(newstr1); //abcdefghahaha

        char data = s.charAt(2);
        System.out.println(data);  //c
        System.out.println(s.indexOf("c")); //2

        System.out.println(s.substring(2)); //cdefg
        System.out.println(s.substring(2,4)); //cd
        System.out.println(s.length()); //7
    }
}
